vector3d GetVertex(void)
Returns
the current vertex location in physical space
vector3d GetVertexByIndex(long index)
Returns
the vertex location in physical space
Parameters
long index:
pass a vertex index here. The internal iterator is automatically adjusted to this vertex index!
VecInt3D GetTriangle(void)
Returns
the current triangle the iterator is pointing to containing the three vertex indices.
VecInt3D GetTriangleByIndex(long index)
Returns
the triangle containing the three vertex indices.
Parameters
long index:
pass a triangle index here. The internal iterator is automatically adjusted to this triangle index!
double GetProperty_Scalar(const ParticleProperty type, BaseObject* node)
Returns
the value of the requested scalar property
Parameters
const ParticleProperty & prop:
the property type to retrieve. See ParticleProperty for a list of properties.
const BaseObject* node_interface:
optionally a property node interface. This is really only necessary if you want to retrieve a custom property
because there can be multiple custom properties of the same type. The node interface is the explicit identifier for such a custom property.
vector3d GetProperty_Vector(const ParticleProperty type, BaseObject* node)
Returns
the value of the requested vector property
Parameters
const ParticleProperty & prop:
the property type to retrieve. See ParticleProperty for a list of properties.
const BaseObject* node_interface:
optionally a property node interface. This is really only necessary if you want to retrieve a custom property
because there can be multiple custom properties of the same type. The node interface is the explicit identifier for such a custom property.
void SetProperty_Scalar(const double new_value, const ParticleProperty type, BaseObject* node)
Overwrites the requested scalar property. If no such property is available it will be created automatically!
Parameters
const double new_value:
the new scalar property value.
const ParticleProperty & prop:
the property type to set. See ParticleProperty for a list of properties.
const BaseObject* node_interface:
optionally a property node interface. This is really only necessary if you want to change a custom property
because there can be multiple custom properties of the same type. The node interface is the explicit identifier for such a custom property.
void SetProperty_Vector(const vector3d& new_value, const ParticleProperty type, BaseObject* node)
Overwrites the requested vector property. If no such property is available it will be created automatically!
Parameters
const vector3d& new_value:
the new vector property value.
const ParticleProperty & prop:
the property type to set. See ParticleProperty for a list of properties.
const BaseObject* node_interface:
optionally a property node interface. This is really only necessary if you want to change a custom property
because there can be multiple custom properties of the same type. The node interface is the explicit identifier for such a custom property.
bool Init (FXVolumeMesh* mesh)
Initialise the iterator for a mesh volume.
Returns
true if the iterator was successfully initialised.
Parameters
FXVolumeMesh* mesh:
the mesh volume to initialise the iterator for.
bool Init (FXMesher* mesh)
Initialise the iterator for a mesher.
Returns
true if the iterator was successfully initialised.
Parameters
FXMesher* mesh:
the mesher to initialise the iterator for.
void Restart(bool tri = true, bool vert = true)
This will reset the iterator so that it points to the first element again.
Parameters
bool tri:
Pass true if you want to iterate triangles.
bool vert:
Pass true if you want to iterate vertices.
bool SetNext(bool tri)
Steps the iterator to get the next triangle or vertex. Used for forward stepping.
Returns
true if the iterator has been incremented.
Parameters
bool tri:
Pass true if you want to increment the triangle iterator. Pass false for incrementing the vertex iterator.
bool SetPrev(bool tri)
Steps the iterator to get the previous triangle or vertex. Used for backward stepping.
Returns
true if the iterator has been decremented.
Parameters
bool tri:
Pass true if you want to decrement the triangle iterator. Pass false for incrementing the vertex iterator.
void Offset(bool tri, long offset)
Offsets the iterator to a user defined position.
You need to make sure yourself the resulting iterator index does not exceed the
particle array bounds!
Parameters
bool tri:
Pass true if you want to offset the triangle iterator. Pass false to offset the vertex iterator.
const long offset:
the iterator offset.
bool OffsetSafe(bool tri, long offset)
Offsets the iterator to a user defined position.
Will automatically make sure the resulting iterator does not exceed the array bounds.
Returns
true if the resulting iterator is valid.
Parameters
bool tri:
Pass true if you want to offset the triangle iterator. Pass false to offset the vertex iterator.
const long offset:
the iterator offset.
bool IsValid(bool tri)
Returns
true if the current iterator is valid.
Parameters
bool tri:
Pass true if you want to check the triangle iterator for validity. Otherwise it will check the vertex iterator.
static FXMeshIterator* Alloc(void)
Allocates the iterator. You can use AutoAlloc for a scope based allocation.
Returns
the mesh iterator. The user owns the pointed object.
static void Free(FXMeshIterator*& p)
Frees a previously allocated Mesh Iterator..
Parameters
FXMeshIterator*&:
Pass the Mesh iterator to free.